<%--
  Created by IntelliJ IDEA.
  User: WYX
  Date: 2024/4/26
  Time: 7:57
  To change this template use File | Settings | File Templates.
--%>
<%@ page contentType="text/html;charset=UTF-8" language="java" %>
<html>
<head>
    <title>day01.jsp</title>
    <link rel="stylesheet" href="../css/day01.css">
</head>
<body>
<div>
    <ul>
        <li>java
            <ul>
                <li>public</li>
                <li>protected</li>
                <li>private</li>
                <li>static</li>
                <li>final</li>
                <li>abstract</li>
                <li>synchronized</li>
                <li>volatile</li>
                <li>transient</li>
            </ul>
        </li>
        <li>jsp
            <ul>
                <li>include</li>
                <li>page</li>
                <li>taglib</li>
                <li>tag</li>
                <li>jspx</li>
            </ul>
        </li>
        <li>C/C++
            <ul>
                <li>int</li>
                <li>float</li>
                <li>double</li>
                <li>char</li>
                <li>bool</li>
                <li>void</li>
                <li>struct</li>
                <li>class</li>
                <li>union</li>
                <li>enum</li>
            </ul>
        </li>
        <li>python
            <ul>
                <li>int</li>
                <li>float</li>
                <li>double</li>
                <li>char</li>
                <li>bool</li>
                <li>void</li>
                <li>struct</li>
                <li>class</li>
                <li>union</li>
                <li>enum</li>
            </ul>
        </li>
    </ul>
</div>
<div>
    <jsp:useBean id="computerBean" class="wyx240426.ComputerBean" scope="request"/>
    <form action="../../computer" method="post">
        <table>
            <tr>
                <td>输入两个数字：</td>
                <td>
                    <label>
                        <input type="text" name="num1">
                    </label>
                </td>
                <td>
                    <label>
                        <input type="text" name="num2">
                    </label>
                </td>
            </tr>
            <tr>
                <td>选择运算符:</td>
                <td>
                    <label>
                        <select name="op">
                            <option value="+">+</option>
                            <option value="-">-</option>
                            <option value="*">*</option>
                            <option value="/">/</option>
                            <option value="%">%</option>
                        </select>
                    </label>
                </td>
                <td>
                    <label>
                        <input type="submit" value="计算">
                    </label>
                </td>
            </tr>
        </table>
    </form>
    <p>运算结果:
        <jsp:getProperty name="computerBean" property="num1"/>
        <jsp:getProperty name="computerBean" property="operator"/>
        <jsp:getProperty name="computerBean" property="num2"/>
        =
        <jsp:getProperty name="computerBean" property="result"/>
    </p>
</div>
</body>
</html>
